﻿using Microsoft.Extensions.Hosting;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Yichat.MicroService.Service
{
    public static class IHostBuilderExtensions
    {
        public static IHostBuilder AddConfigOptionConfiguration(this IHostBuilder hostBuilder)
        {
            return hostBuilder.ConfigureAppConfiguration((context, configBuiler) =>
            {
                var config = configBuiler.Build();
                configBuiler.AddConfigOptionConfiguration(config);
            });
        }
    }
}
